package com.tanjie.blackbean.pojo.response;

/**
 * @author: tanjie
 * @date: 2022-03-30
 **/
public enum CommonCode implements IResult {

    SUCCESS(DEFAULT_SUCCESS_MESSAGE, DEFAULT_SUCCESS_CODE),
    FAILURE(DEFAULT_FAILURE_MESSAGE, DEFAULT_FAILURE_CODE);

    CommonCode(String message, Integer code) {
        this.message = message;
        this.code = code;
    }

    final String message;

    final Integer code;

    @Override
    public String getMessage() {
        return this.message;
    }

    @Override
    public Integer getCode() {
        return this.code;
    }

}
